package com.作业.Day1;

import com.homwork.Bean.Employee;
import com.homwork.Bean.Phone;

public class Homework1 {
    public static void main(String[] args) {
        /**
         *   利用建造者模式进行构造对象
         */
        Phone phone = Phone.builder()
                .price(100)
                .Brand("华为")
                .Model("麒麟9000芯片")
                .memory("512GB").build();
        System.out.println("我的手机:"+phone.toString());

        Employee employee = Employee.builder()
                .number("2300103201")
                .age(20)
                .posts("java工程师")
                .count(20000).build();
        System.out.println("员工收入:"+employee.toString());

    }
}
